﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Globalization;
using System.Web.Mvc;
using System.Web.Security;
using BussinessLogic.Models;

namespace BussinessLogic.Models.Study
{
    public class StudyListItemModel
    {
        public int ID { get; set; }

        [Display(Name = "Name")]
        public string Name { get; set; }

        [Display(Name = "Description")]
        public string Description { get; set; }

        [Display(Name = "Active")]
        public bool Active { get; set; }

        public bool IsRunning { get; set; }
    }

    public class StudyPresentationModel
    {
        public int ID { get; set; }

        
        [Display(Name = "Name")]
        public string Name { get; set; }

        [Display(Name = "Description")]
        public string Description { get; set; }

        [Display(Name = "Prerequisites")]
        public List<StudyPrerequisitesModel> Prerequisites { get; set; }

        [Display(Name = "Informed consent")]
        public string InformedConsent { get; set; }

        public bool Enrolled { get; set; }

        public bool Approved { get; set; }
    }

    public class StudyCreateModel
    {
        [Required]
        [Display(Name = "Name")]
        public string Name { get; set; }

        [Display(Name = "Description")]
        public string Description { get; set; }
        
        [Display(Name = "Prerequisites")]
        public List<StudyPrerequisitesModel> Prerequisites { get; set; }

        [Display(Name = "Informed consent")]
        public string InformedConsent { get; set; }

        [Display(Name = "Active")]
        public bool Active { get; set; }
    }

    public class StudyPrerequisitesModel
    {
        [Display(Name = "Name")]
        public string Name { get; set; }

        [Display(Name = "Description")]
        public string Description { get; set; }
    }

    public class StudyProtocol
    {
        public int StudyID { get; set; }
        public string StudyName { get; set; }
        public List<GroupStudy> Groups { get; set; }
        public List<StudyExercise> Activities { get; set; }

        public bool IsRunning { get; set; }
    }

    public class GroupStudy
    {
        public string Name { get; set; }
        public int Repeat { get; set; }
        public List<StudySession> Sessions { get; set; }
    }

    public class StudySession
    {
        public string Name { get; set; }
        public List<StudyExercise> Exercises { get; set; }
        public int Repeat { get; set; }
    }

    public class StudyExercise
	{
        public int ID { get; set; }
        public int Repeat { get; set; }
        public string Name { get; set; }
	}

}
